
package Convertisseur;

import java.util.HashMap;
import java.util.Iterator;

import Convertisseur.VariableFlags;

public class InitFor_QDAS_catalog extends VariableFlags{
	//definition for Q_DAS

	//new table
	protected static String OP100_Tool [] = {"1001", "1002", "1003", "1004"};
	protected static String OP105_Tool [] = {"1051", "1052", "1053", "1054"};
	protected static String OP110_Tool [] = {"1101", "1102", "1103", "1104"};
	protected static String OP115_Tool [] = {"1151", "1152", "1153", "1154"};
	protected static String OP120_Tool [] = {"1201", "1202", "1203", "1204"};
	protected static String OP125_Tool [] = {"1251", "1252", "1253", "1254"};
	protected static String OP130_Tool [] = {"1301", "1302", "1303", "1304"};
	protected static String OP135_Tool [] = {"1351", "1352", "1353", "1354"};
	protected static String OP140_Tool [] = {"1401", "1402", "1403", "1404"};
	protected static String OP145_Tool [] = {"1451", "1452", "1453", "1454"};
	protected static String OP150_Tool [] = {"1501", "1502", "1503", "1504"};
	protected static String OP155_Tool [] = {"1551", "1552", "1553", "1554"};
	protected static String OP160_Tool [] = {"1601", "1602", "1603", "1604"};
	protected static String OP165_Tool [] = {"1651", "1652", "1653", "1654"};
	protected static String OP170_Tool [] = {"1701", "1702", "1703", "1704"};
	protected static String OP175_Tool [] = {"1751", "1752", "1753", "1754"};
	protected static String OP180_Tool [] = {"1801", "1802", "1803", "1804"};
	protected static String OP185_Tool [] = {"1851", "1852", "1853", "1854"};
	protected static String OP190_Tool [] = {"1901", "1902", "1903", "1904"};
	protected static String OP195_Tool [] = {"1951", "1952", "1953", "1954"};
	protected static String OP200_Tool [] = {"2001", "2002", "2003", "2004"};

	protected static enum OP_Infu{
		OP100, OP105, OP110, OP115, OP120, OP125, OP130, OP135, OP140, OP145, 
		OP150, OP155, OP160, OP165, OP170, OP175, OP180, OP185, OP190, OP195, OP200;
	}
	protected static HashMap<String, String> OP_Influencing_table_QDAS = new HashMap<String, String>();
	protected static HashMap<String, String[]> OP_Tool_table_QDAS = new HashMap<String, String[]>();

	
	public static HashMap<String, String> getOP_Influencing_table_QDAS() {
		return OP_Influencing_table_QDAS;
	}

	public static void setOP_Influencing_table_QDAS(
			HashMap<String, String> oP_Influencing_table_QDAS) {
		OP_Influencing_table_QDAS = oP_Influencing_table_QDAS;
	}

	public static HashMap<String, String[]> getOP_Tool_table_QDAS() {
		return OP_Tool_table_QDAS;
	}

	public static void setOP_Tool_table_QDAS(
			HashMap<String, String[]> oP_Tool_table_QDAS) {
		OP_Tool_table_QDAS = oP_Tool_table_QDAS;
	}

	public static void initialize_OP_Influencing(){
		//initialize OP_Influencing
		/*
		for(OP_Infu op: OP_Infu.values()){
			OP_Influencing_table_QDAS.put(op.name(), ""+(op.ordinal()+6));
		}	
		*/
		//for new table Q_DAS
		for(OP_Infu op: OP_Infu.values()){
			String op_number = op.name();
			op_number = op_number.replace("OP", "");
			OP_Influencing_table_QDAS.put(op.name(), ""+op_number);
		}
		
		//initialize OP_Tool
		OP_Tool_table_QDAS.put("OP100", OP100_Tool);
		OP_Tool_table_QDAS.put("OP105", OP105_Tool);
		OP_Tool_table_QDAS.put("OP110", OP110_Tool);
		OP_Tool_table_QDAS.put("OP115", OP115_Tool);
		OP_Tool_table_QDAS.put("OP120", OP120_Tool);
		OP_Tool_table_QDAS.put("OP125", OP125_Tool);
		OP_Tool_table_QDAS.put("OP130", OP130_Tool);
		OP_Tool_table_QDAS.put("OP135", OP135_Tool);
		OP_Tool_table_QDAS.put("OP140", OP140_Tool);
		OP_Tool_table_QDAS.put("OP145", OP145_Tool);
		OP_Tool_table_QDAS.put("OP150", OP150_Tool);
		OP_Tool_table_QDAS.put("OP155", OP155_Tool);
		OP_Tool_table_QDAS.put("OP160", OP160_Tool);
		OP_Tool_table_QDAS.put("OP165", OP165_Tool);
		OP_Tool_table_QDAS.put("OP170", OP170_Tool);
		OP_Tool_table_QDAS.put("OP175", OP175_Tool);
		OP_Tool_table_QDAS.put("OP180", OP180_Tool);
		OP_Tool_table_QDAS.put("OP185", OP185_Tool);
		OP_Tool_table_QDAS.put("OP190", OP190_Tool);
		OP_Tool_table_QDAS.put("OP195", OP195_Tool);
		OP_Tool_table_QDAS.put("OP200", OP200_Tool);
		
		
	}
	
	public void afficherLesMap(){
		//--------------------------------------------------------------------------------
		// show Maps
		//--------------------------------------------------------------------------------	
		//show values of HashMap OP
		Iterator<String> iterator = OP_Tool_Path.keySet().iterator();
		while(iterator.hasNext()){
			Object key = iterator.next();
			System.out.println("Map"+key+" valus: "+OP_Tool_Path.get(key));
		}		
		
		//show values of HashMap OP_Influencing
		Iterator<String> iterator2 = OP_Influencing_table_QDAS.keySet().iterator();
		while(iterator2.hasNext()){
			Object key = iterator2.next();
			System.out.println("OP_Influencing "+key+" valus: "+OP_Influencing_table_QDAS.get(key));
		}
		
		//show values of HashMap OP_Tool
		Iterator<String> iterator3 = OP_Tool_table_QDAS.keySet().iterator();
		while(iterator3.hasNext()){
			Object key = iterator3.next();
			System.out.println("OP_Tool "+key+" valus: "+OP_Tool_table_QDAS.get(key)[0]+","
													+OP_Tool_table_QDAS.get(key)[1]+","
													+OP_Tool_table_QDAS.get(key)[2]+","
													+OP_Tool_table_QDAS.get(key)[3]);
		}
		//--------------------------------------------------------------------------------	
		// fin show Maps
		//--------------------------------------------------------------------------------
		
	}
	
	public static void main(String [] agrs){
		InitFor_QDAS_catalog init = new InitFor_QDAS_catalog();
		InitFor_QDAS_catalog.initialize_OP_Influencing();
		init.afficherLesMap();
		
		
	}
}
